Use method not defined in Interface [Java]

Posted by Samuel on Stack Overflow See other posts from Stack Overflow or by Samuel
Published on 2010-04-28T18:53:23Z Indexed on 2010/04/28 18:57 UTC
Read the original article Hit count: 443

Filed under:
|
|
|

Hello World,

I have an assignment and i got a library including an interface class. [InfoItem]

I implement this class [Item].

Now i am required to write a method watchProgram(InfoItem item) [other class, importing InfoItem], which (as shown) requires an InfoItem.

The passed parameter item has a variable 'Recorded' [boolean] which i want to edit using a method changeRecorded() that i defined in the implementation of InfoItem.

I cannot edit the interface and i get an error message that the method is not found [cannot find symbol]..

Any hints, suggestions, solutions? Thanks!!

-Samuel-

© Stack Overflow or respective owner

Related posts about java

Related posts about interface